package com.dcw.lixb.designmode.composite;

/**
 * @author lixiaobin
 * @date 2020-07-22 15:09:19
 * @desc 描述信息
 */
public class CompositeMain {
    public static void main(String[] args) {

        Employee employeeLdh = new Employee("刘德华", "CEO", 100000);


        Employee employeeZs = new Employee("张三", "电子技术", 10000);
        Employee employeeLs = new Employee("李四", "电子技术", 8000);
        Employee employeeWw = new Employee("王五", "电子技术", 8000);
        Employee employeeZl = new Employee("赵六", "电子技术", 8000);

        employeeLdh.addSubordinate(employeeZs);
        employeeZs.addSubordinate(employeeLs);
        employeeZs.addSubordinate(employeeWw);
        employeeZs.addSubordinate(employeeZl);


        System.out.println(employeeLdh);
    }
}
